package org.example.springmybatis.controller;

import org.example.springmybatis.model.UserInfo;
import org.example.springmybatis.mapper.UserInfoMapper;
import org.springframework.beans.factory.annotation.Autowired;
import org.springframework.stereotype.Service;

import java.util.List;

@Service
public class UserService {
    @Autowired
    private UserInfoMapper userInfoMapper;
    public List<UserInfo> getAllUser() {
        return userInfoMapper.selectAll();
    }

    public UserInfo getUserInfoById() {
        return userInfoMapper.selectAllById();
    }
}
